package com.hhkj.study.admin.config.service.base.impl;

import com.github.pagehelper.PageInfo;
import com.hhkj.study.admin.config.entity.ConfigWelcome;
import com.hhkj.study.admin.config.mapper.ConfigWelcomeMapper;
import com.hhkj.study.admin.config.model.podo.ConfigWelcomeDo;
import com.hhkj.study.admin.config.model.podo.ConfigWelcomePo;
import com.hhkj.study.admin.config.service.base.ConfigWelcomeService;
import com.ruoyi.common.base.biz.service.base.BaseServiceImpl;
import org.springframework.stereotype.Service;

import java.util.HashMap;
import java.util.Map;

/**
*
* @author SERVER
* @since 2024-09-06
*/
@Service
public class ConfigWelcomeServiceImpl extends BaseServiceImpl<ConfigWelcome, ConfigWelcomeDo, ConfigWelcomePo, ConfigWelcomeMapper> implements ConfigWelcomeService {

    @Override
    public PageInfo<ConfigWelcomePo> pagingPoByDo(ConfigWelcomeDo conditionDo) {
        conditionDo.getPageDomain().setOrderByColumn("orderNum");
        conditionDo.getPageDomain().setIsAsc("asc");
        return super.pagingPoByDo(conditionDo);
    }

    @Override
    public Map<String, String> getOrderColumnMap() {
        return new HashMap<String, String>() {{
            put("orderNum", "xcw.order_num");
            put("id", "xcw.id");
        }};
    }
}